<?php

namespace App\model;

use Illuminate\Database\Eloquent\Model;
use DB;
class Operation extends Model
{
	/*
	*@content 权限
	*@author  
    */

	public $table = 'operation';
    public $timestamps = false;

	/**
	 * 页面操作记录
	 */

	 public function pageWork($ip,$use_id,$url)
	{
	  $descPower=DB::table('power')->where('p_url',$url)->first();
	  $desc=$descPower->p_desc;
      $this->insert([
		  'ope_ip'=>$ip,
		  'ope_date'=>date("Y-m-d H:i:s"),
		  'ope_desc'=>$desc,
		  'use_id'=>$use_id,
	  ]);
	}

}